import {issueTypeList, issueSourceList} from "@/utils/const.js"

export const tableColumn = {
  sysCode: {
    label: "系统代号",
    columnProp: {
      align: 'center',
      minWidth: '110px'
    }
  },
  sysName: {
    label: "系统名称",
    columnProp: {
      align: 'center',
      minWidth: '120px',
      "show-overflow-tooltip" : true
    }
  },
  deviceCode: {
    label: "单机代号",
    columnProp: {
      align: 'center',
      minWidth: '110px',
      "show-overflow-tooltip" : true
    }
  },
  deviceName: {
    label: "单机名称",
    columnProp: {
      align: 'center',
      minWidth: '110px',
      "show-overflow-tooltip" : true
    }
  },
  // qualityTitle: {
  //   label: '详情标题',
  //   columnProp: {
  //     align: 'center',
  //     minWidth: '120px',
  //     "show-overflow-tooltip" : true
  //   }
  // },
  qualityDescribe: {
    label: '质量问题概述',
    type: 'link',
    text: '查看详情',
    valueField: 'qualityTitle',
    columnProp: {
      align: 'center',
      minWidth: '120px'
    }
  },
  qualityType: {
    label: '质量问题类别',
    type: 'select',
    selectOption: JSON.parse(JSON.stringify(issueTypeList)),
    columnProp: {
      align: 'center',
      minWidth: '140px'
    }
  },
  qualitySource: {
    label: '质量问题来源',
    type: 'select',
    selectOption: JSON.parse(JSON.stringify(issueSourceList)),
    columnProp: {
      align: 'center',
      minWidth: '140px'
    },
  },
  qualityProgress: {
    label: '质量问题进度跟踪',
    type: 'issue-tracking',
    columnProp: {
      align: 'center',
      'width': '174px',
      'class-name': 'pd-3-0'
    },
    valueMap: {
      value: 'qualityProgressPlan',
      progress: 'qualityProgress',
      count: 'qualityProgressNum'
    }
  },
  calculateProgress: {
    label: '举一反三进度跟踪',
    type: 'issue-tracking',
    columnProp: {
      align: 'center',
      'width': '174px',
      'class-name': 'pd-3-0'
    },
    valueMap: {
      value: 'calculateProgressPlan',
      progress: 'calculateProgress',
      count: 'calculateProgressNum'
    }
  },
  qualityColor: {
    label: '完成度',
    progress:true,
    value:'qualityProp',
    linkText: '',
    columnProp: {
      align: 'center',
      minWidth: '110px'
    }
  },
  focus: {
    label: '关注',
    type: 'focus',
    columnProp: {
      align: 'center'
    }
  }
}